/**
 * chenuu.com
 * 
 * @author  zhaoxu.com@gmail.com
 * @created 2012-11-10
 */
package com.chenuu.integration.dropbox.api;

import com.chenuu.integration.dropbox.model.AccessType;
import com.chenuu.integration.dropbox.model.DropboxAccount;
import com.chenuu.integration.dropbox.model.DropboxEntry;
import com.chenuu.integration.dropbox.oauth.token.OAuthToken;
import com.chenuu.integration.dropbox.session.DropboxSession;
import com.dropbox.client2.exception.DropboxException;

/**
 *
 */
public interface DropboxAPI {

	OAuthToken requestToken() throws DropboxException;

	String authorize(OAuthToken requestToken);

	OAuthToken accessToken(DropboxSession session) throws DropboxException;
	
	DropboxAccount accountInfo(DropboxSession session) throws DropboxException;

	DropboxEntry metadata(DropboxSession session, AccessType accessType, String path,
			int fileLimit, String hash, boolean list) throws DropboxException;

	void download(DropboxSession session, AccessType accessType, String dropboxPath, String localPath)
			throws DropboxException;

	void upload(DropboxSession session, AccessType accessType, String dropboxPath, String localPath)
			throws DropboxException;
}
